<!-- 顶部栏 -->
<header class="main-header">
	<!-- 左侧 Logo -->
	<a href="" class="logo">
		<!-- 小Logo 在缩小时使用 -->
		<span class="logo-mini"><img src="<?php echo STC_RES ?>stuff/img/favicon.ico"> </span>
		<!-- 大Logo -->
		<span class="logo-lg"><img src="<?php echo STC_RES ?>stuff/img/favicon.ico">中南大学升华网</span>
	</a>
	<!-- 顶部导航栏 -->
	<nav class="navbar navbar-static-top" role="navigation">
		<!-- Sidebar toggle button-->
		<a href="#" class="sidebar-toggle" data-toggle="push-menu" role="button">
			<span class="sr-only">侧边栏</span>
		</a>
		<!-- 导航栏右侧 -->
		<div class="navbar-custom-menu">
			<ul class="nav navbar-nav">
				<!-- 用户菜单 -->
				<li class="dropdown user user-menu">
					<!-- 菜单切换按钮 -->
					<a href="#" class="dropdown-toggle" data-toggle="dropdown">
						<!-- 导航栏小头像 -->
						<img src="{$self.qqimg}" class="user-image"
						     alt="User Image">
						<!-- 导航栏小介绍 -->
						<span class="hidden-xs">{$self.name}</span>
					</a>
					<ul class="dropdown-menu">
						<!-- 菜单内头像 -->
						<li class="user-header">
							<img src="{$self.qqimg}" class="img-circle"
							     alt="User Image">
							<p>
								{$self.name}
								<small>{$self.branch} {$self.position}</small>
							</p>

						</li>
						<!-- 菜单项 -->
						<li class="user-body">
							<div class="row">
								<div class="col-xs-4 text-center">
									<a href="#">Followers</a>
								</div>
								<div class="col-xs-4 text-center">
									<a href="#">Sales</a>
								</div>
								<div class="col-xs-4 text-center">
									<a href="#">Friends</a>
								</div>
							</div>
						</li>
						<!-- 菜单底部 -->
						<li class="user-footer">
							<div class="pull-left">
								<a href="#" class="btn btn-default btn-flat">Profile</a>
							</div>
							<div class="pull-right">
								<a href="#" class="btn btn-default btn-flat">Sign out</a>
							</div>
						</li>
					</ul>
				</li>
				<!-- 控制栏切换按钮 -->
				<li>
					<a href="#" data-toggle="control-sidebar"><i class="fa fa-gears"></i></a>
				</li>
			</ul>
		</div>
	</nav>
</header>

<!-- 左边栏 -->
<aside class="main-sidebar">
	<!-- 侧边栏 -->
	<section class="sidebar">
		<!-- 用户信息 -->
		<div class="user-panel">
			<div class="pull-left image">
				<img src="{$self.qqimg}" class="img-circle"
				     alt="User Image">
			</div>
			<div class="pull-left info">
				<!--<br/>-->
				<p>赵旭阳</p>
				<!-- 状态 -->
				<a href="#"><i class="fa fa-circle text-success"></i> Online</a>
			</div>
		</div>

		<!-- 搜索框 -->
		<!--			<form action="#" method="get" class="sidebar-form">-->
		<!--				<div class="input-group">-->
		<!--					<input type="text" name="q" class="form-control" placeholder="Search...">-->
		<!--					<span class="input-group-btn">-->
		<!--              <button type="submit" name="search" id="search-btn" class="btn btn-flat"><i-->
		<!--			              class="fa fa-search"></i>-->
		<!--              </button>-->
		<!--            </span>-->
		<!--				</div>-->
		<!--			</form>-->
		<!-- /.search form -->

		<!-- 侧边栏主菜单 -->
		<ul class="sidebar-menu" data-widget="tree">
			<li class="header">盛世升华网 服务中南人</li>
			<!-- 左侧菜单 可以加入icon -->
			{php}
			foreach ($self['authority'] as $key => $value) {
				if (is_array($value)) {
					echo '<li class="treeview">
				<a href="#"><i class="fa fa-link"></i> <span>' . $key . '</span>
					<span class="pull-right-container">
                <i class="fa fa-angle-left pull-right"></i>
              </span>
				</a>
				<ul class="treeview-menu">';
					foreach ($value as $item) {
						echo '<li><a href="#">' . $item . '</a></li>';
					}
					echo '</ul>
			</li>';
				} else {
					echo '<li><a href="#"><i class="fa fa-link"></i><span>' . $value . '</span></a></li>';
				}
			}
			{/php}
		</ul>
	</section>
</aside>